/*
 * Copyright 2019-2025 the original author or authors.
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 * https://www.apache.org/licenses/LICENSE-2.0
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package com.iiifi.kite.security.model;

import java.util.Map;

import com.iiifi.kite.security.utils.KiteUtils;

import lombok.Data;

/**
 * 鉴权模型
 *
 * @author kite@iiifi.com 花朝
 */
@Data
public class KiteAuthForm {

    /**
     * 登录鉴权
     */
    public static final String LOGIN_AUTH = "LOGIN_AUTH";

    /**
     * 资源鉴权
     */
    public static final String RESOURCE_AUTH = "RESOURCE_AUTH";

    /**
     * 服务名
     */
    private String appName;

    /**
     * token
     */
    private String token;

    /**
     * deviceId
     */
    private String deviceId;

    /**
     * 请求路径
     */
    private String path;

    /**
     * 请求方法
     */
    private String method;

    /**
     * 参数列表
     */
    private Map<String, String> parameters;

    /**
     * LOGIN_AUTH:登录鉴权,RESOURCE_AUTH:资源鉴权
     */
    private String authType = KiteAuthForm.LOGIN_AUTH;

    /**
     * starter版本
     */
    private String sdkVersion = KiteUtils.SDK_VERSION;
}
